# Maintainer: Maxime Gauduin <alucryd@archlinux.org>
# Contributor: Sándor Nagy <sanya868@gmail.com>
# Contributor: Jeramy Harrison <dbralir@gmail.com>
# Contributor: Onni R. <onnir@iki.fi>

pkgname=png++
pkgver=0.2.10
pkgrel=2
pkgdesc='A C++ wrapper for libpng'
arch=(any)
url=https://savannah.nongnu.org/projects/pngpp/
license=(custom)
depends=(libpng)
makedepends=(doxygen)
source=(https://download.savannah.gnu.org/releases/pngpp/png++-${pkgver}.tar.gz)
validpgpkeys=(FFDEBBD8758B0D1BB9359F6FDAAAD54650B717C8)
sha256sums=('998af216ab16ebb88543fbaa2dbb9175855e944775b66f2996fc945c8444eee1')

prepare() {
  cd png++-${pkgver}

  sed "s/0.2.9/${pkgver}/g" -i Makefile
}

build() {
  cd png++-${pkgver}

  make docs
}

package() {
  cd png++-${pkgver}

  make PREFIX="${pkgdir}/usr" install

  install -dm 755 "${pkgdir}"/usr/share/licenses/png++
  install -m 644 COPYING "${pkgdir}"/usr/share/licenses/png++/
}

# vim: ts=2 sw=2 et:
